package com.weixin.project.Common.Enum;

public enum ClassField {
    DATA_STRUCTURE("数据结构"),
    COMPUTER_COMPOSITION_PRINCIPLE("计算机组成原理"),
    COMPUTER_NETWORK("计算机网络"),
    OPERATING_SYSTEM("操作系统"),
    AUTHENTIC("真题");
    private String chineseName;
    private ClassField(String chineseName){
        this.chineseName = chineseName;
    }

    public String getChineseName() {
        return chineseName;
    }

    public void setChineseName(String chineseName) {
        this.chineseName = chineseName;
    }

    public static ClassField chineseNameOf(String chineseName){
        for (ClassField classField: values()){
            if (classField.getChineseName().equals(chineseName)){
                return classField;
            }
        }
        return null;
    }
}
